home *** CD-ROM | disk | FTP | other *** search
/ Collection of Tools & Utilities / Collection of Tools and Utilities.iso / system / idcutils.zip / TESTDRV.BAT < prev    next >
DOS Batch File  |  1990-05-20  |  770b  |  31 lines

  1. ECHO OFF
  2. REM
  3. REM    Infinity Design Concepts, Inc.
  4. REM    1052 Parkway drive
  5. REM    Louisville, Kentucky 40217-2333
  6. REM
  7. REM     This is a sample batch file that demonstrates the use of
  8. REM    the CHKDRV.EXE program. The program will return an errorlevel
  9. REM    value that gives information about the status of a specified
  10. REM    drive.
  11. REM
  12. IF %1a==a GOTO CMDERROR
  13. CHKDRV %1
  14. REM returns ERRORLEVEL with one of the following values
  15. REM
  16. REM  ERRORLEVEL = 0 - drive is ready
  17. REM  ERRORLEVEL = 1 - drive is not ready
  18. REM
  19. IF ERRORLEVEL 1 GOTO NOTREADY
  20. ECHO   Drive %1 is READY
  21. GOTO END
  22. :NOTREADY
  23. ECHO   Drive %1 is NOT READY
  24. GOTO END
  25. :CMDERROR
  26. ECHO   Drive letter must be specified on command line
  27. ECHO   Example: to test drive A:
  28. ECHO       TESTDRV A
  29. GOTO END
  30. :END
  31.